package routes

import (
	"github.com/gin-gonic/gin"
	"pro/internal/handler"
	"pro/internal/middleware"
)

func Routes(r *gin.Engine) {

	r.POST("user/sms", handler.SendSms)
	r.POST("user/login", handler.Login)
	r.POST("upload", handler.UploadImage)
	r.POST("tieZi/add", handler.AddTieZi)

	auth := r.Group("/api/")
	auth.Use(middleware.AuthUserMiddleware())
	{

	}
	r.GET("tieZi/search", handler.TieZiSearch)
	r.POST("comment/add", handler.CreateComments)
	r.GET("web/fl", handler.HandleWebSocket)
	r.POST("follow", handler.FollowCreate)

	r.POST("likes/add", handler.CreateLikesLog)

	r.POST("likes/del", handler.DelLikesLog)

	r.GET("userInfo", handler.GetUserInfo)

	r.POST("userInfo/update", handler.UpdateUserInfo)
}
